package com.water.expert.extraction.repository;

import java.util.List;

import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.CrudRepository;

// This will be AUTO IMPLEMENTED by Spring into a Bean called userRepository
// CRUD refers Create, Read, Update, Delete

public interface ExtractionResultRepository extends CrudRepository<ExtractionResult, Long> {
	@Query("SELECT er FROM ExtractionResult er WHERE er.extraction.id = :extractionId")
	List<ExtractionResult> findByExtractionId(Long extractionId);
}
